﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class CinderellaSkill : SkillBase
{

    public float speedupRatio = 2f;

    public PlayerController playerController;

    public override void Cast()
    {
        if (!isInCooldown())
        {
            lastCastTime = Time.time;
            StartCoroutine(SkillCountdown());
        }
    }

    public override void skillStart()
    {
        Debug.Log("skill start");
        playerController.m_speed *= speedupRatio;
    }
    public override void skillEnd()
    {
        Debug.Log("skill end");
        transform.localScale = new Vector3(1.6f, 1.6f, 1);

        playerController.m_speed /= speedupRatio;

    }
    // Start is called before the first frame update
    void Start()
    {
        playerController = GetComponent<PlayerController>();

    }

    // Update is called once per frame
    void Update()
    {
        
    }
}
